import request from "@/utils/request";
import type {AjaxResult,page} from "@/utils/request"

const base = '/blog/comment'

export const getCommentList = (data : any , params? :page) : Promise<AjaxResult> => {
    return request({
        url: `/blog/comment/list`,
        method: 'post',
        data : data,
        params: params
    })
}

export const addComment = (data) => {
    return request({
        url: `/blog/comment/add`,
        method: 'post',
        data:data
    })
}

export const detComment = (id) => {
    return request({
        url: `${base}/delete/${id}`,
        method: 'delete',
    })
}
